/* 
接口可以描述函数类型
*/
interface SearchFunc {
  (source: string, subString: string): boolean
}


const fun: SearchFunc = (x: string, y: string): boolean => {
  return x.includes(y)
}

console.log(fun('abcd', 'bc'))